a41d09bda3121cfc81e0286786b49c6cf2b650be,src/com/opencms/flex/jsp/CmsJspTagFileProperty.java,CmsJspTagFileProperty,propertyTagAction,#String#String#String#CmsFlexRequest#,111
Before Change
result = CmsPropertyLookup.lookupProperty(req.getCmsObject(), req.getCmsRequestedResource(), property, true);
} else {
// Read properties of the file named in the attribute
result = CmsPropertyLookup.lookupProperty(req.getCmsObject(), req.toAbsolute(action), property, false);
}
if ((defaultValue != null) && (result == null)) {
result = defaultValue;
}
After Change
return SKIP_BODY;
}
public static String propertyTagAction(String property, String action, String defaultValue, CmsFlexRequest req)
throws CmsException
{
// Make sure that no null String is returned
if (defaultValue == null) defaultValue = "";
if ("parent".equals(action)) {
// Read properties of parent (i.e. top requested) file
return req.getCmsObject().readProperty(req.getCmsRequestedResource(), property, false, defaultValue);
} else if ("this".equals(action)) {
// Read properties of this file
return req.getCmsObject().readProperty(req.getCmsResource(), property, false, defaultValue);
} else if ("search-this".equals(action)) {
// Try to find property on this file and all parent folders
return req.getCmsObject().readProperty(req.getCmsResource(), property, true, defaultValue);
} else if ("search-parent".equals(action) || "search".equals(action)) {
// Try to find property on parent file and all parent folders
return req.getCmsObject().readProperty(req.getCmsRequestedResource(), property, true, defaultValue);
} else {
// Read properties of the file named in the attribute
return req.getCmsObject().readProperty(req.toAbsolute(action), property, false, defaultValue);
}
}